﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.ServiceModel;
using System.ServiceModel.Web;
using System.Text;
using System.Threading.Tasks;

namespace MotionControl.Modules.Restful
{
    [ServiceContract(Name = "MCServices")]
    public interface IMCCommand
    {
        [OperationContract]
        [WebGet(UriTemplate = "mc/plc/{cmd}", BodyStyle = WebMessageBodyStyle.Bare, RequestFormat = WebMessageFormat.Json, ResponseFormat = WebMessageFormat.Json)]
        bool PLCCommand(string cmd);

        [OperationContract]
        [WebGet(UriTemplate = "mc/light/{lightParam}", BodyStyle = WebMessageBodyStyle.Bare, RequestFormat = WebMessageFormat.Json, ResponseFormat = WebMessageFormat.Json)]
        bool LightCommand(string lightParam);

        //[OperationContract]
        //[WebInvoke(Method = "POST", UriTemplate = "MC/Info", BodyStyle = WebMessageBodyStyle.Bare, RequestFormat = WebMessageFormat.Json, ResponseFormat = WebMessageFormat.Json)]
        //bool GetInfo(Mesdata info);    
    }
}
